﻿<%@ Control Language="C#" AutoEventWireup="true" CodeFile="housecategory.ascx.cs" Inherits="mwc_admin_controls_housecategory" %>
<div style="padding:10px;">
    <p style="font-size: 12pt;"><b>House Category</b></p>
    
    <asp:Panel ID="cat_list" runat="server">
        <asp:Label ID="list_tb" runat="server" />
        <asp:GridView ID="gvListCat" runat="server" AutoGenerateColumns="false">
            <Columns>
                <asp:BoundField ItemStyle-Width="5%"  DataField="id" HeaderText="ID" InsertVisible="false" ReadOnly="true" SortExpression="id" />
                <asp:BoundField   DataField="catname" HeaderText="Category Name" InsertVisible="false" ReadOnly="true" SortExpression="catname" />
                <asp:HyperLinkField ItemStyle-Width="10%" HeaderText="Edit" Text="Change" DataNavigateUrlFields="id" DataNavigateUrlFormatString="~/mwc_admin/Panel.aspx?option=housecategory&task=edit&id={0}" />
            </Columns>
        </asp:GridView>
    </asp:Panel>

    <asp:Panel ID="cat_input" runat="server"> 
        <asp:Label ID="detail_tb" runat="server" />
        <table style="width:100%;">
        <tr>
            <td style="width:20%;"><b>Category Name: </b></td>
            <td><asp:TextBox ID="cat_name" runat="server" /></td>
        </tr>
        <tr>
            <td style="width:20%;"><b>Enable: </b></td>
            <td><asp:CheckBox ID="cat_enable" runat="server" Checked="true" /></td>
        </tr>
        </table>
        <br />
        <div style="width: 100%;padding: 0 0 0 15px;"><asp:Button ID="cat_save" runat="server" Text="Save" OnClick="saveCat" style="padding:0 15px 0 15px;" /><asp:Button ID="cat_cancel" runat="server" OnClick="turnBack" Text="Cancel" style="padding:0 15px 0 15px;" /></div>
    </asp:Panel>
</div>
